package cn.changeforyou.analyzer.combine.orm;

import cn.changeforyou.analyzer.xmlparse.mybatis.reader.AbstractXmlLabelReaderWriter;
import cn.changeforyou.analyzer.xmlparse.mybatis.reader.AliasColumnListReaderWriter;
import cn.changeforyou.analyzer.xmlparse.mybatis.reader.AliasResultMapLabelReaderWriter;
import cn.changeforyou.analyzer.xmlparse.mybatis.reader.BaseColumnListReaderWriter;
import cn.changeforyou.analyzer.xmlparse.mybatis.reader.BaseResultMapLabelReaderWriter;
import lombok.Getter;

public enum XmlCodeType {
	BaseResultMap("基础结果集", 0, new BaseResultMapLabelReaderWriter()),
	AliasResultMap("别名结果集", 1, new AliasResultMapLabelReaderWriter()),
	Base_Column_List("基础column列表", 2, new BaseColumnListReaderWriter()),
	Alias_Column_List("别名column列表", 3, new AliasColumnListReaderWriter()),
	
	;
	
	XmlCodeType(String description, int bitPosition, AbstractXmlLabelReaderWriter readerWriter) {
		this.description = description;
		this.readerWriter = readerWriter;
		this.bitPosition = bitPosition;
	}
	
	@Getter
	private String description;
	@Getter
	private AbstractXmlLabelReaderWriter readerWriter;
	
	@Getter
	/**
	 * 存储时二进制的位置
	 */
	private int bitPosition;
}